
#ifndef _CANVAS_H_
#define _CANVAS_H_

#include <SDL/SDL.h>
#include "Widget.h"

namespace animationagent {

class Canvas : public Widget
{
private:
    SDL_Surface *image;

    void init();

public:

    void set_image(SDL_Surface *pic);
    SDL_Surface *get_image();
    virtual void draw(SDL_Surface *screen);
    virtual void update();
    //virtual void set_colorkey(Uint8 r, Uint8 g, Uint8 b);
    //virtual void set_alpha(Uint8 a);
    //void alpha_fade_out(Uint32 duration);
    //void alpha_fade_in(Uint32 duration);
    Canvas();
    Canvas(SDL_Surface *pic);
    virtual ~Canvas();
};

}//end namespace animationagent

#endif
